const {ccclass, property} = cc._decorator;
import GameModel from "./Model/GameModel";
import UserModel from "./Model/UserModel";
import WindowUtils from "./Tools/WindowUtils";

@ccclass
class AppDelegate {
    public userModel:UserModel = null;
    public gameModel:GameModel = null;
    
    constructor() {}
    init () {
        WindowUtils.init();
        this.gameModel = new GameModel();
        this.gameModel.init();

        this.userModel = new UserModel();
        this.userModel.init();
        
        var manager = cc.director.getCollisionManager();
        manager.enabled = true;
        manager.enabledDebugDraw = true;    // 碰撞检测范围
        // manager.enabledDrawBoundingBox = true; //碰撞组件的包围盒
        
        cc.director.getPhysicsManager().enabled = true;
    }

}

export default new AppDelegate();